<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link href="/bootstrap/css/bootstrap.css" rel="stylesheet">
    <script src="/bootstrap/js/bootstrap.min.js"></script>
</head>
<body>
<h1>学生信息</h1>
<a th:href="@{/student/add}">添加</a>
<a th:href="@{/logout}">注销</a>
<div class="container">
    <table class="table table-hover">
        <tr>
            <th>学号</th>
            <th>姓名</th>
            <th>性别</th>
            <th>年龄</th>
            <th>地址</th>
            <th colspan="2">操作</th>
        </tr>
        <tr th:each="student:${studentList}">
            <td th:text="${student.sno}"></td>
            <td th:text="${student.sname}"></td>
            <td th:text="${student.sex}"></td>
            <td th:text="${student.age}"></td>
            <td th:text="${student.address}"></td>
            <td><a th:href="@{/student/edit(sno=${student.sno})}">编辑</a></td>
            <td><a th:href="@{/student/delete(sno=${student.sno})}">删除</a></td>
        </tr>
    </table>
</div>
</body>
</html>